switchroot: Use MS_MOVE to / rather than chroot
authorColin Walters <walters@verbum.org>
Tue, 12 Feb 2013 01:46:53 +0000 (20:46 -0500)
committerColin Walters <walters@verbum.org>
Tue, 12 Feb 2013 01:46:53 +0000 (20:46 -0500)
commitc9f56564a374be6051e62ec97da3b340da21ff54
treeef1e9fa3079a2517fac4307aba10cd0a9c98b279
parent1d98f8865cc068a60eb71df26d8ddfa83a5dc64b
switchroot: Use MS_MOVE to / rather than chroot

This fixes a number of bugs; the two biggest are:

1) On shutdown systemd can correctly umount /
2) We can use linux-user-chroot inside the system, as is
   necessary to do upgrades

See http://lists.freedesktop.org/archives/systemd-devel/2012-September/006703.html
src/switchroot/ostree-switch-root.c